home *** CD-ROM | disk | FTP | other *** search
/ PC-Blue - MS DOS Public Domain Library / PC-Blue MS-DOS Public Domain Library - NYACC.iso / vol174 / tutor < prev    next >
Encoding:
Text File  |  1986-11-24  |  60.6 KB  |  1,541 lines

  1.  
  2.          
  3.          
  4.          
  5.  
  6.  
  7.  
  8.  
  9.  
  10.  
  11.  
  12.  
  13.                                      ESIE
  14.  
  15.  
  16.                        The Expert System Inference Engine
  17.  
  18.  
  19.                                      Tutor
  20.  
  21.  
  22.  
  23.  
  24.  
  25.  
  26.  
  27.  
  28.  
  29.  
  30.  
  31.  
  32.  
  33.  
  34.  
  35.  
  36.  
  37.          Lightwave Consultants                           August 1985
  38.          P.O. Box 290539
  39.          Tampa, FL  33617
  40.  
  41.  
  42.  
  43.  
  44.  
  45.  
  46.  
  47.                       Copyright 1985, All Rights Reserved.
  48.  
  49.          The ESIE distribution diskette, of which this tutor is one 
  50.          file, may be freely copied and distributed.  Printed copies 
  51.          of this tutor, or this tutor without the rest of the files on 
  52.          the distribution diskette, may not be copied or reproduced in 
  53.          any form. 
  54.  
  55.  
  56.                                                                 Page 2
  57.  
  58.  
  59.                                Table of Contents
  60.  
  61.  
  62.          Introduction  . . . . . . . . . . . . . . . . . . . . . .  3
  63.  
  64.          What is Shareware?  . . . . . . . . . . . . . . . . . . .  4
  65.  
  66.          What is Artificial Intelligence?  . . . . . . . . . . . .  5
  67.  
  68.          Types of Artificial Intelligence  . . . . . . . . . . . .  6
  69.  
  70.          What is ESIE? . . . . . . . . . . . . . . . . . . . . . .  9
  71.  
  72.          What I Need to Get Started  . . . . . . . . . . . . . . . 10
  73.  
  74.          Starting ESIE . . . . . . . . . . . . . . . . . . . . . . 11
  75.  
  76.          The ESIE Top Level  . . . . . . . . . . . . . . . . . . . 12
  77.  
  78.          Some Example Knowledge Bases  . . . . . . . . . . . . . . 13
  79.  
  80.               Animal . . . . . . . . . . . . . . . . . . . . . . . 15
  81.  
  82.               Doctor . . . . . . . . . . . . . . . . . . . . . . . 19
  83.  
  84.               Glass  . . . . . . . . . . . . . . . . . . . . . . . 21
  85.  
  86.          Building Your Own Knowledge Base  . . . . . . . . . . . . 22
  87.  
  88.          Paying For and Obtaining the Next Version of ESIE . . . . 26
  89.  
  90.          Bibliography  . . . . . . . . . . . . . . . . . . . . . . 27
  91.  
  92.          Biography . . . . . . . . . . . . . . . . . . . . . . . . 28
  93.  
  94.  
  95.  
  96.  
  97.  
  98.  
  99.  
  100.  
  101.  
  102.  
  103.  
  104.  
  105.  
  106.  
  107.  
  108.  
  109.  
  110.  
  111.                                                                 Page 3
  112.  
  113.  
  114.                                   Introduction
  115.  
  116.  
  117.          ESIE (pronounced "easy") is the acronym for Expert System 
  118.          Inference Engine.  ESIE is, according to many people working 
  119.          in Artificial Intelligence (AI), an "expert system shell." 
  120.  
  121.          With ESIE you can put some "smarts" into your personal 
  122.          computer.  You can build custom "knowledge bases" (KBs) that 
  123.          can be used to aid people, like you and me, in doing things 
  124.          that we would not be capable of doing, or doing as well, 
  125.          without the system.  ESIE knowledge bases can be built to 
  126.          help us make decisions or to make our computers "more human." 
  127.  
  128.          This manual is designed for the person who has absolutely no 
  129.          experience in the field of Artificial Intelligence (AI).  
  130.          This manual is intended to give you: a working knowledge of 
  131.          AI, help you learn about ESIE, give you enough information to 
  132.          build your own knowledge bases, and provide some tips for 
  133.          building better knowledge bases in the future.  When you have 
  134.          completed this tutorial you should print and read the file 
  135.          MANUAL, which gives all the details concerning ESIE. 
  136.  
  137.          For those of you who may by interested in the history of AI, 
  138.          please print and read the file HISTORY, which gives a short 
  139.          history of Artificial Intelligence.  If you only intend on 
  140.          using ESIE with a knowledge base written for you, then you 
  141.          need only print and read the file USER. 
  142.  
  143.          I assume that you have no experience in AI whatsoever, but I 
  144.          further assume that you have done some work, or at least some 
  145.          reading, in the operation of your computer.  Neither this 
  146.          tutorial, nor any file distributed with ESIE, will try to 
  147.          educate you concerning your equipment.  However, operation of 
  148.          ESIE is very straightforward and you need only know the 
  149.          rudiments (i.e. how to turn your computer on) to use the ESIE 
  150.          system. 
  151.  
  152.          In any case, welcome to ESIE.  ESIE is my own work and I take 
  153.          full responsibility for its abilities and its shortcomings. 
  154.  
  155.  
  156.  
  157.  
  158.  
  159.  
  160.  
  161.  
  162.  
  163.  
  164.  
  165.  
  166.                                                                 Page 4
  167.  
  168.  
  169.                                What Is Shareware?
  170.  
  171.  
  172.          Shareware is a software distribution concept.  In shareware, 
  173.          it is believed: that people will pay for something they find 
  174.          useful, that most software costs too much, that copy 
  175.          protection schemes can sometimes be frustrating even to the 
  176.          most honest user, and that software users want to support 
  177.          software authors while not necessarily supporting the 
  178.          software middle men.  
  179.  
  180.          Shareware is a marketing concept.  The term was probably 
  181.          originally coined by Bob Wallace of Quicksoft, Inc.  Mr. 
  182.          Wallace wrote PC-Write (c), a shareware full-feature text 
  183.          editor.  I personally like PC-Write and prefer it as my own 
  184.          editor.  I believe you will find PC-Write useful and to that 
  185.          end I will send you a copy of it if you "pay" for ESIE at the 
  186.          $145 level.  Many of the Shareware ideas in ESIE come 
  187.          directly from PC-Write(c) and I offer my public thanks. 
  188.  
  189.          ESIE is distributed under the Shareware concept.  You receive 
  190.          the software first, from whatever source that may be, and pay 
  191.          only what you think the software is worth.  You are free, and 
  192.          encouraged, to share copies of the distribution diskette with 
  193.          others. 
  194.  
  195.          ESIE is marketed under the shareware concept.  I prefer to 
  196.          think of ESIE as living software: software that continues to 
  197.          develop and get better, more powerful.  I believe ESIE is a 
  198.          useful tool as it is, but can be improved.  However, support 
  199.          for living software must come from someone.  Even we software 
  200.          authors and AI researchers can't live on discovery and love 
  201.          alone.  In shareware this support comes from you - the user. 
  202.  
  203.          If you feel that ESIE is useful to you, send what your 
  204.          conscience dictates.  ESIE is paid for on the honor system.  
  205.          However, if you send at least $75 you will receive the most 
  206.          recent version of ESIE, free.  If you send at least $145 you 
  207.          will receive: the most recent version of ESIE, fully  
  208.          commented source code for ESIE (ESIE was written in Pascal), 
  209.          my sincere thanks for your support, a copy of PC-Write (c) - 
  210.          a shareware full-feature text editor fully compatible with 
  211.          ESIE, and access to a help line, all free. 
  212.  
  213.          Your comments towards ESIE are solicited even if you do not 
  214.          desire support.  For this, please print and fill out the file 
  215.          FORM and send it in.  Mail and money for ESIE can be sent to: 
  216.          Lightwave Consultants; P.O. Box 290539; Tampa, FL 33617. 
  217.  
  218.  
  219.  
  220.  
  221.                                                                 Page 5
  222.  
  223.  
  224.                         What is Artificial Intelligence?
  225.  
  226.  
  227.          Now here is a good question.  Whenever a bunch of knowledge 
  228.          engineers (KEs) get together for social hour this subject has 
  229.          a way of rubbing us the wrong way.  In short, not even we can 
  230.          decide on a good definition of AI.  I'll give you my view in 
  231.          a moment, but now for the currently "accepted" view: 
  232.  
  233.               "I think of AI - Artificial Intelligence - as 
  234.               performance by computers of tasks which, if they are 
  235.               done by people, would require intelligence."  (1) 
  236.  
  237.          Although I have immense respect for Dr. Simon, and consider 
  238.          him to be one of the true "fathers" of AI, I have a little 
  239.          trouble with this definition.  First, an argument can be 
  240.          struck (and has been - believe me), that ALL computer 
  241.          software fits this definition as any task the computer does 
  242.          would probably require intelligence if a person were doing 
  243.          the same thing.  Second, if you define intelligence to mean 
  244.          the ability to remember facts than all computers have a 200+ 
  245.          IQ.  Third, why restrict the definition to computers? 
  246.  
  247.          Although my definition is not the accepted one, I think I 
  248.          have heard more than one (at least two) KEs voice their 
  249.          approval:  "Artificial Intelligence occurs when a man-made 
  250.          system gathers data and makes a recommendation."  You notice 
  251.          that I allow other systems besides computers to be 
  252.          considered.  The recommendation part is key.  A system that 
  253.          simply catalogues or computes is not AI under my definition.  
  254.          Also, an AI system does not have to make a recommendation to 
  255.          a human, it can even be to another system. 
  256.  
  257.          Well, enough of that.  For a working definition of AI, at 
  258.          least until the tide changes, consider it as any activity 
  259.          that a computer does that is human-like. 
  260.  
  261.  
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268.  
  269.  
  270.  
  271.  
  272.  
  273.  
  274.  
  275.  
  276.                                                                 Page 6
  277.  
  278.  
  279.                         Types of Artificial Intelligence
  280.  
  281.  
  282.          If you could isolate every type of activity a human does, 
  283.          then you probably have found all the different types of AI.  
  284.          Let me list some of the most active ones in existence today: 
  285.  
  286.          Natural Language (NL) is the field where researchers are 
  287.          trying to get machines to understand natural English, or some 
  288.          other human language.  It is not as easy as you might think.  
  289.          For a widely known example, the sentence "the spirit is 
  290.          willing but the flesh is weak", was translated into "the wine 
  291.          is agreeable but the meat is spoiled" by an NL program. 
  292.  
  293.          Machine Vision (MV) is the area where researchers are trying 
  294.          to get machines to see.  Some of this work can be the most 
  295.          fascinating research in the world.  I recommend it if you are 
  296.          in the mood for a career change.  Past research has been 
  297.          concentrating on understanding how humans see and trying to 
  298.          duplicate that process in machines.  Now, I believe, the 
  299.          trend is to use the special capabilities of the machine, such 
  300.          as infared detection and laser range finding in order to give 
  301.          the machine vision. 
  302.  
  303.          Expert system (ES) research is the area that ESIE fits in.  
  304.          It is involved with making the machine reason and think like 
  305.          a human.  Although no current ES has creativity, I'm sure it 
  306.          will be classified as an ES when the creative capability is 
  307.          made.  Nearly all, if not all, ESs in existence today run on 
  308.          the KB principle.  Knowledge based systems is also the area 
  309.          that is receiving the most recognition from industry as it 
  310.          has advanced enough to be useful.  In KB systems, human 
  311.          reasoning is coded into the computer in production rules.  
  312.          The set of these rules makes up the knowledge base. 
  313.  
  314.          Machine Listening (ML) works with the area of synthetic 
  315.          speech.  Both speech recognition and speech synthesis come 
  316.          under the heading of Machine Listening.  This too is 
  317.          fascinating work, and some real breakthroughs are expected 
  318.          very soon. 
  319.  
  320.          Robotics works primarily in the area of motor control, 
  321.          tactile processing, and location determination.  Robotic 
  322.          companies are increasing their sphere, however, and I'm sure 
  323.          they will soon be using all the capabilities of AI.
  324.  
  325.          There are two typical applications in existence today where 
  326.          expert systems are used.  One is the area of decision tree 
  327.          applications and the other is in the area of data query. 
  328.  
  329.          In decision tree systems a solution set is coded into a 
  330.          machine to solve a particular problem set.  A good example of 
  331.                                                                 Page 7
  332.          decision tree systems are medical systems.  In these, a 
  333.          typical first question might be:  "Does the patient have a 
  334.          fever?".  Based on the answer to that question an entire area 
  335.          of diseases will be eliminated, and the next level of the 
  336.          tree will be selected. 
  337.  
  338.          Many knowledge bases today are built to run in the same 
  339.          "inference engine."  These inference engines can use the 
  340.          rules in a multitude of different KBs, so they are useful in 
  341.          many tasks.  An inference engine is the computer program that 
  342.          captures the raw inferencing power of the human mind.  It 
  343.          uses the knowlege in the KB to act with human reasoning 
  344.          capability. 
  345.  
  346.          In data query systems there is typically a natural language 
  347.          front end.  This front end allows the end user to query a 
  348.          data base in natural English commands.  The system has to 
  349.          solve for what the end user really wants and then go get and 
  350.          manipulate the appropriate data.  An example of this type of 
  351.          system is where the question might be asked: "Should I hire 
  352.          more people before the year ends?" 
  353.  
  354.          Both of the above are applications in knowledge based 
  355.          systems.  While neither are becoming static in their 
  356.          application, they are becoming somewhat standard in 
  357.          implementation. 
  358.  
  359.          A third form of expert, or knowledge based, system involves 
  360.          the process.  This type of ES has been largely ignored by the 
  361.          AI community, but is starting to get large press in AI 
  362.          journals and papers.  It is receiving notice in corporations 
  363.          due to its low cost and quick payback period.  A process 
  364.          based system is trying to assist a human in completing some 
  365.          task. 
  366.  
  367.          The goal in process based systems (PBS) is to automate that 
  368.          terribly lengthy, hard-to-read, impossible-to-use manual or 
  369.          intruction set.  The interactive capability of PBSs are one 
  370.          of their nice features.  ESIE can be used to build a PBS, but 
  371.          its main intent is for decision algorithms, where a decision 
  372.          or goal is to be reached. 
  373.  
  374.          Expert systems are those computer applications that code 
  375.          human knowledge, usually from one or more human experts in 
  376.          the target field, into a form were the machine can mimic that 
  377.          expertise.  The human expertise is coded in one or more files 
  378.          called the "knowledge base" (KB). 
  379.  
  380.          Expert systems can be self-improving with time.  That is, it 
  381.          is possible to build an ES that adds more information to its 
  382.          knowledge base as it is being used.  Many practitioners argue 
  383.          against adding this capability, as it is possible for the KB 
  384.          to become indeterminant when conflicting rules are added. 
  385.  
  386.                                                                 Page 8
  387.          If you want to know more about AI in general, then please 
  388.          print and read the file HISTORY.
  389.  
  390.  
  391.  
  392.  
  393.  
  394.  
  395.  
  396.  
  397.  
  398.  
  399.  
  400.  
  401.  
  402.  
  403.  
  404.  
  405.  
  406.  
  407.  
  408.  
  409.  
  410.  
  411.  
  412.  
  413.  
  414.  
  415.  
  416.  
  417.  
  418.  
  419.  
  420.  
  421.  
  422.  
  423.  
  424.  
  425.  
  426.  
  427.  
  428.  
  429.  
  430.  
  431.  
  432.  
  433.  
  434.  
  435.  
  436.  
  437.  
  438.  
  439.  
  440.  
  441.                                                                 Page 9
  442.  
  443.  
  444.                                  What Is ESIE?
  445.  
  446.  
  447.          ESIE is the acronym for Expert System Inference Engine, and 
  448.          that is exactly what it is.  ESIE loads in a knowledge base, 
  449.          and builds inferences out of the rules contained therein, to 
  450.          act like an advisor.  It is an Artificial Intelligence expert 
  451.          system shell.  An infinite multitude of knowledge bases can 
  452.          be used by ESIE. 
  453.  
  454.          What is an expert system shell (ESS)?  ESSs are used to take 
  455.          the rules coded in the knowledge base and use these rules in 
  456.          a consulting session with a person.  The person using the ESS 
  457.          with the KB to help him reach a decision is called the user.  
  458.          The coding of the rules into the KB is done by someone called 
  459.          the knowledge engineer. 
  460.  
  461.          The normal gamut of expert systems (ES) can be built for and 
  462.          used by ESIE.  Tools such as computer system configurators, 
  463.          medical experts, oil and gas exploration, etc, can all be 
  464.          done in ESIE.  
  465.  
  466.          The acronym was also selected because ESIE is easy to use.  
  467.          ESIE is much easier to use than most ESSs available today.  I 
  468.          can vividly remember thinking, "They've got to be kidding" 
  469.          with at least three different ESSs.  Further, I am sure that 
  470.          if I uncovered one more "undiscovered" bug in an ESS that I 
  471.          would be a permanent resident at Bellevue.  ESIE has been 
  472.          fully tested and checked out, and since it was written in 
  473.          Pascal, it should hold you in good stead.
  474.  
  475.          If you were, or are, currently working for a corporation or 
  476.          university then you are also aware of the difficulty in 
  477.          getting management approval for a very expensive piece of 
  478.          equipment.  Most AI equipment and software is prohibitively 
  479.          expensive except for the best funded AI departments.  ESIE is 
  480.          built to put some competitiveness into the ESS market.  
  481.  
  482.          ESIE is very inexpensive and rivals many ESSs in power and it 
  483.          beats nearly all in speed.  Also, for markets, ESIE is 
  484.          uniquely fitted.  Knowledge based inference engines have a 
  485.          rather small market at present, but that soon may change.  I 
  486.          hope the advent of low cost and readily available software 
  487.          might help the spread and acceptance of AI. 
  488.  
  489.  
  490.  
  491.  
  492.  
  493.  
  494.  
  495.  
  496.                                                                Page 10
  497.  
  498.  
  499.                            What I Need to Get Started
  500.  
  501.  
  502.          In order to use ESIE you don't need much at all.  For 
  503.          hardware you will need: an MS-DOS (r) or IBM (r) computer 
  504.          with at least 128 KB of RAM, and a color or monochrome 
  505.          monitor.  ESIE should run on any MS-DOS (r) computer, (it has 
  506.          been tested on several), but I just can not guarantee that it 
  507.          will run on your particular machine.  ESIE will run on the 
  508.          IBM PC jr, PC, XT, and AT (r).  
  509.  
  510.          You will also need the ESIE distribution diskette, DOS 2.0 or 
  511.          higher, and a compatible word processor.  Read the sections:  
  512.          ESIE Requirements and The ESIE Distribution Diskette in the 
  513.          manual for more information.  You probably received 
  514.          everything you needed when you got the ESIE distribution 
  515.          diskette.
  516.  
  517.  
  518.  
  519.  
  520.  
  521.  
  522.  
  523.  
  524.  
  525.  
  526.  
  527.  
  528.  
  529.  
  530.  
  531.  
  532.  
  533.  
  534.  
  535.  
  536.  
  537.  
  538.  
  539.  
  540.  
  541.  
  542.  
  543.  
  544.  
  545.  
  546.  
  547.  
  548.  
  549.  
  550.  
  551.                                                                Page 11
  552.  
  553.  
  554.                                  Starting ESIE
  555.  
  556.  
  557.          Getting ESIE fired up will probably be one of the easiest 
  558.          things you do today.  The only two files you need in the 
  559.          computer to use ESIE are the ESIE.COM file and the file where 
  560.          the KB is.  Of course, you may have as many files out there 
  561.          as you wish.  For purposes of demonstration, it will be 
  562.          assumed that you are using the ANIMAL example KB provided 
  563.          with the distribution diskette.  When you start to build your 
  564.          own KBs, simply substitute that file for ANIMAL.  ESIE will 
  565.          run in any drive and directory, including hard disks, as long 
  566.          as the ESIE.COM and KB files are present. 
  567.  
  568.          When you have at least the above two files where you want 
  569.          them, simply type in ESIE at the DOS prompt.  The ESIE 
  570.          introductory screen will appear.  It contains information 
  571.          about the Shareware concept and some benefits you will 
  572.          receive if you pay for your copy of ESIE. 
  573.  
  574.          At the top of the introductory screen is a prompt asking you 
  575.          to supply the file name where the knowledge base may be 
  576.          found.  Type in ANIMAL.  If the file exists, then ESIE will 
  577.          attempt to load that file.  If no loading errors are found, 
  578.          then ESIE will take you to the top level. If there are errors 
  579.          in loading the KB, then ESIE will list where it found the 
  580.          errors and return you to DOS. If the file does not exist, 
  581.          then you have the option of trying again.  Just hitting the 
  582.          'Y' or the 'N' key will answer this prompt.  ESIE loads files 
  583.          faster than most, if not all, other expert system shells, but 
  584.          be patient if you are loading a very large KB, especially 
  585.          from floppy diskette. 
  586.  
  587.  
  588.  
  589.  
  590.  
  591.  
  592.  
  593.  
  594.  
  595.  
  596.  
  597.  
  598.  
  599.  
  600.  
  601.  
  602.  
  603.  
  604.  
  605.  
  606.                                                                Page 12
  607.  
  608.  
  609.                                The ESIE Top Level
  610.  
  611.  
  612.          You will know when you have reached the top level by the 
  613.          distinctive ESIE prompt.  It looks like this: "==>".  At the 
  614.          top level you have four different command options:  TRACE ON, 
  615.          TRACE OFF, GO, and EXIT.  While you can have as many leading 
  616.          and trailing blanks as you wish, ESIE is not quite free form 
  617.          on the command line; you must have one and only one space 
  618.          between the TRACE and YES/NO options.  Other than that, ESIE 
  619.          is free form. 
  620.  
  621.          Importantly, ESIE is case insensitive.  Caps look just the 
  622.          same as smalls to ESIE.  This is also true in the KB and in 
  623.          end user responses.  ESIE is case insensitive everywhere.  I 
  624.          like this feature: I hate building rules to take care of the 
  625.          same idea but duplicated everywhere to take care of case, and 
  626.          the idea that a variable means something different because 
  627.          the first letter is capitalized drives me up the wall. 
  628.  
  629.          When you first enter the top level, trace is off by default.  
  630.          You can turn trace on using the TRACE ON command.  Use trace 
  631.          when you are building your own KB and want to follow 
  632.          execution in order to debug the KB.  Turning trace on will 
  633.          tell the system to constantly keep you informed of what it is 
  634.          currently looking for and what information it has learned. 
  635.  
  636.          You can turn the trace back off again by entering the TRACE 
  637.          OFF command. 
  638.  
  639.          The GO command is the command to tell ESIE to begin a 
  640.          consultation with the KB that was loaded.  ESIE will continue 
  641.          with this consultation until it is complete or until an error 
  642.          is found in the logic of the KB.  You may not turn trace on 
  643.          or off once a consultation has begun.  If the user types in 
  644.          TRACE ON, TRACE OFF, GO or EXIT in response to a question, 
  645.          then ESIE will treat that as the response to the question. 
  646.  
  647.          Once ESIE has completed the consultation, or found an error 
  648.          in the logic of the KB, it will return you to the top level 
  649.          for additional commands. 
  650.  
  651.          Use the EXIT command in order to leave ESIE and return to 
  652.          DOS.  After a consultation is complete, you have the option 
  653.          of entering ANY of the four commands, including GO, again. 
  654.  
  655.  
  656.  
  657.  
  658.  
  659.  
  660.  
  661.                                                                Page 13
  662.  
  663.  
  664.                           Some Example Knowledge Bases
  665.  
  666.  
  667.          In order to get you used to the ESIE rule structure, three 
  668.          sample KBs have been included on the distribution diskette. 
  669.  
  670.          ANIMAL is a KB that plays "twenty questions" with you in 
  671.          order to find out what type of animal you are thinking about.  
  672.          Before typing in 'GO' to ESIE, after loading the ANIMAL KB, 
  673.          think of an animal you want ESIE to try and find.  Answer the 
  674.          questions put to you about the animal and ESIE will find out 
  675.          what animal it is in far less than twenty questions.  ANIMAL 
  676.          is a decision tree KB that is fully structured. 
  677.  
  678.          A fully structured KB indicates that there is a terminating 
  679.          leaf on every path of the decision tree.  In a fully 
  680.          structured KB it is impossible for the rules in the KB to be 
  681.          mixed up or out of order - there is one and only one path to 
  682.          every single goal in the KB.  These types of KBs usually take 
  683.          the most effort to build, but are the most satisfying in 
  684.          their completion.  You generally "map out" how the 
  685.          information should look before you begin coding.  For 
  686.          example: 
  687.  
  688.  
  689.                                          type.transportation
  690.                                      /\
  691.                                     /  \
  692.                                    /    \
  693.                                   /      \
  694.                                  /2.wheels\ 4.wheels
  695.                                 /\        /\
  696.                                /  \      /  \
  697.                               /    bike  car \
  698.                              /motor           \
  699.                             /\                 \
  700.                            /  \                truck
  701.                           /    \
  702.                          /      \
  703.                       moped    bicycle
  704.  
  705.          Note that the leaves can be similar, but there is a 
  706.          terminating leaf for every path in the tree.  In these types 
  707.          of KBs, the user response is usually limited to YES and NO.  
  708.          ANIMAL is much like this. 
  709.  
  710.          This is what a session with ANIMAL looks like.  The splats 
  711.          indicate output from ESIE: 
  712.  
  713.               go
  714.               Does your animal have a backbone?                      *
  715.               yes
  716.                                                                Page 14
  717.               Is the animal warm blooded?                            *
  718.               yes
  719.               Normally, does the female of your animal nurse         *
  720.                    its young with milk?                              *
  721.               yes
  722.               Does your animal eat red meat?                         *
  723.               yes
  724.               Does your animal have finger wings?                    *
  725.               no
  726.               Does your animal have an opposing thumb?               *
  727.               yes
  728.               Does your animal have a prehensile tail?               *
  729.               no
  730.               Is your animal nearly hairless?                        *
  731.               yes
  732.                                                                      *
  733.               I think your animal is a MAN                           *
  734.                                                                      *
  735.               I have completed this analysis.                        *
  736.                                                                      *
  737.               ==>                                                    *
  738.  
  739.  
  740.          DOCTOR is a KB that is used to diagnose diseases in children.  
  741.          Do not take DOCTOR too literally, please.  I am no physician, 
  742.          and the information in the KB came out of a single book.  The 
  743.          KB was built in about 8 hours.  The DOCTOR KB is there just 
  744.          to show off ESIE and is not meant to replace your physician.  
  745.          DOCTOR is a decision tree KB and is not fully structured. 
  746.  
  747.          I coded DOCTOR and ANIMAL in two distinct styles in order to 
  748.          demonstrate ESIE's capabilities.  
  749.  
  750.          GLASS is rather special for me.  First, I didn't write it.  I 
  751.          asked a friend of mine to be one of the beta testers for ESIE 
  752.          and she came up with GLASS.  She has no experience in AI 
  753.          whatsoever.  GLASS demonstrates ESIE's ease of use.  GLASS is 
  754.          used to give an evaluation of antique or depression era 
  755.          glass, which has gathered quite a following from what I 
  756.          understand. 
  757.  
  758.  
  759.  
  760.  
  761.  
  762.  
  763.  
  764.  
  765.  
  766.  
  767.  
  768.  
  769.  
  770.  
  771.                                                                Page 15
  772.  
  773.  
  774.          Some Example Knowledge Bases                       Animal
  775.  
  776.  
  777.          ANIMAL is a fully structured decision tree knowledge base.  
  778.          In order to build ANIMAL I gathered information concerning 
  779.          the classification of the animal kingdom.  
  780.          
  781.          Gathering information on any subject that you wish to put 
  782.          into an ES will probably be the toughest part of your job as 
  783.          a KE.  I good approach I've found is to begin by listing all 
  784.          the possible terminations of the decision tree.  In ANIMAL 
  785.          all the terminations are the different animals, such as BEAR, 
  786.          FOX, etc.
  787.          
  788.          Then, using additional information, group the terminations 
  789.          into categories at the highest possible level and in as few 
  790.          categories as possible - hopefully two.  In ANIMAL, the 
  791.          highest categorization offered by my information was does the 
  792.          animal have a backbone?  I know what you are thinking: that 
  793.          is not a good classification if one considers all the 
  794.          possible animals in the world.  But I was not working with 
  795.          all the possible animals in the world, I decided at the 
  796.          outset to limit the number of animals to those that a person 
  797.          has a pretty good chance of thinking about.  This included 
  798.          all the mammals, etc.  Other animals are grouped into large 
  799.          single terminators, such as 'insect.' 
  800.          
  801.          Now that you have all your terminators broken down into two 
  802.          categories, the next step is to take one of the two 
  803.          categories and break it into two smaller categories.  
  804.          Continue in this fashion until ALL your catagories have been 
  805.          dismantled down to the terminator level.  You should have 
  806.          something that looks like the decision tree in the previous 
  807.          section. 
  808.          
  809.          Now let me diverge for a moment to discuss decision points, 
  810.          depth, and KB cleanliness.  At every "fork" in the knowledge 
  811.          base you have what is called a decision point.  Here is where 
  812.          the work of a KB is carried out.  Depth is how far down in 
  813.          the KB you currently are.  For example, in the previous 
  814.          decision tree chart: 2.wheels and 4.wheels are on the same 
  815.          level, and motor, bike, car, and truck are also on the same 
  816.          level, but a different level than 2.wheels and 4.wheels.  
  817.          Motor, bike, car, and truck are said to be a level "deeper" 
  818.          than 2.wheels and 4.wheels. 
  819.          
  820.          As you break up your knowledge base you often separate 
  821.          terminators based on qualities you as KE have determined.  
  822.          For example, I used backbone as a determining factor in 
  823.          ANIMAL, but there really are several very high order 
  824.          qualifications for animals.  The phylum Chordata is the only 
  825.          one having backbones, and it made up about half of my 
  826.                                                                Page 16
  827.          terminators.  Therefore, I chose backbone as the highest 
  828.          level qualifier.
  829.          
  830.          Now that you have your decision tree made there are two ways 
  831.          to write the KB: first, you can write each terminator with 
  832.          all of its qualifiers in each rule, or you can write rules 
  833.          for each decision point.  If you remember your mathematics 
  834.          for expontial versus geometric expansion, you will see that 
  835.          it is better, and often easier to debug, if you choose the 
  836.          rule per decision point method.  If you choose the former 
  837.          method not only would you be typing forever, but the KB may 
  838.          be too big to be operated on by an ESS. 
  839.          
  840.          Ok.  So you decide to start coding ANIMAL, and although it 
  841.          does not matter where in the tree you start or go to, I 
  842.          always start at the top and kind of work left to right.  We 
  843.          have decided the initial question is going to be: "Does your 
  844.          animal have a backbone?", and you are going to set something 
  845.          based on the answer to that question. 
  846.          
  847.          However, you can not determine the type of animal from the 
  848.          existence of a backbone, so you must create "level 
  849.          designators."  These designators determine which path you 
  850.          take at any given level or decision point.  Many times they 
  851.          are artificial.  For example, I used the level designators in 
  852.          ANIMAL of SUPERPHYLUM, PHYLUM, CLASS, ORDER, FAMILY, GENUS, 
  853.          SPECIES, SUBSPECIES, and SUBSUBSPECIES.  While these are, 
  854.          indeed, the qualifiers used in animal classification (except 
  855.          subspecies and subsubspecies), animal clasification does not 
  856.          follow the desired YES/NO, or binary, approach.  Therefore, 
  857.          my level designators are artificial. 
  858.          
  859.          Level designators are used to determine which path to take in 
  860.          the tree.  It is a good idea to use one level designator per 
  861.          level in the tree, making sure that assignments to that 
  862.          designator are unique throughout the tree.
  863.          
  864.          A note about style and KB cleanliness here.  Some practiced 
  865.          KEs will tell you that you can use the same level designator 
  866.          everywhere in the tree.  This is true.  However, if you use 
  867.          the same level designator everywhere in the tree debugging 
  868.          your KB may become impossible, because you have no idea where 
  869.          you currently are in a consultation.  The trace function on 
  870.          many packages becomes nearly useless because you are always 
  871.          looking for the same thing.  Point of interest:  some texts 
  872.          may call the level designator the decision designator. 
  873.          
  874.          Also, some KEs pick a unique designator for every decision 
  875.          point.  You may do this if you like, and it may be useful on 
  876.          especially difficult KBs, but is not often required.  One 
  877.          level designator per tree level is usually fine. 
  878.          
  879.          Then begin coding your KB.  The first rules will be the one 
  880.          concerning backbone. 
  881.                                                                Page 17
  882.          
  883.               if has.backbone is yes
  884.               then superphylum is backbone
  885.          
  886.               if has.backbone is no
  887.               then superphylum is jellyback
  888.          
  889.          Since you need this information from the user, you include 
  890.          the QUESTION rule: 
  891.          
  892.               question has.backbone 
  893.               is "Does the animal have a backbone?"
  894.          
  895.          For the next rule in the KB you decide to go down the right 
  896.          hand side of the tree where the warm blooded qualifier 
  897.          splits up your terminators.  Therefore you have to ask about 
  898.          the warm-bloodedness of your animal.  Caution, here however, 
  899.          because the warm blooded attribute has nothing to do with the 
  900.          left side of the tree.  Therefore, you have to make sure you 
  901.          are only dealing with the right side of the tree.  To do this 
  902.          you incude an AND qualifier in the rules:
  903.          
  904.               if superphylum is backbone
  905.               and warm.blooded is yes
  906.               then phylum is warm
  907.          
  908.               if superphylum is backbone
  909.               and warm.blooded is no
  910.               then phylum is cold
  911.          
  912.          Several things to note here.  First, we are going down a 
  913.          level in the tree, so phylum becomes our next level 
  914.          designator instead of superphylum.  The superphylum part of 
  915.          the rule goes first, otherwise you would be asking your user 
  916.          questions that may not pertain to his animal, in this case 
  917.          about the animal's warm-bloodedness.  In the above two rules 
  918.          you are again splitting the decision path in the decision 
  919.          tree.  You will generally have one rule per link in the tree. 
  920.          
  921.          You continue in this fashion until you have reached the 
  922.          terminators, upon where a rule will look like this:
  923.          
  924.               if species is notail
  925.               and nearly.hairless is yes
  926.               then type.animal is man
  927.          
  928.          ESIE works by tying in terminator rules with rules they 
  929.          reference, and rules those rules reference, etc., all the way 
  930.          to the top of the tree.  In ANIMAL, the species part refers 
  931.          to a genus part, which refers to a order part, etc., all the 
  932.          way up to the backbone rules.  
  933.          
  934.          Continue writing rules in this fashion until you have written 
  935.          an appropriate rule for every link, and an appropriate 
  936.                                                                Page 18
  937.          question for every decision point.  If you print out and read 
  938.          ANIMAL you will see what I'm talking about.  You can 
  939.          reconstruct the decision tree I used by looking at the ANIMAL 
  940.          KB. 
  941.          
  942.          The next thing you need to do is to tell ESIE which one of 
  943.          the qualifiers in the KB we are really looking for.  This is 
  944.          the goal, or the reason for the consultation: 
  945.          
  946.               goal is type.animal
  947.          
  948.          ESIE will stop the consultation when he finds out what 
  949.          type.animal is.
  950.          
  951.          You can learn more about how ESIE works by reading the manual 
  952.          that comes with this diskette and by paying for the source 
  953.          code that was used to build ESIE. 
  954.          
  955.          By being fully structured, ANIMAL has a terminator for every 
  956.          path through the decision tree.  No matter what the user 
  957.          responds, ESIE will come up with an animal for him.  
  958.          
  959.  
  960.  
  961.  
  962.  
  963.  
  964.  
  965.  
  966.  
  967.  
  968.  
  969.  
  970.  
  971.  
  972.  
  973.  
  974.  
  975.  
  976.  
  977.  
  978.  
  979.  
  980.  
  981.  
  982.  
  983.  
  984.  
  985.  
  986.  
  987.  
  988.  
  989.  
  990.  
  991.                                                                Page 19
  992.  
  993.          
  994.          Some Example Knowledge Bases                      Doctor
  995.          
  996.  
  997.          DOCTOR is a non fully structured decision tree knowledge 
  998.          base.  Non fully structured means different things to 
  999.          different AI researchers: for one it means that there are 
  1000.          decision points in the tree that are not connected to the 
  1001.          rest of the tree, for another it means that the ESS may not 
  1002.          come up with a conclusion for every possible set of end user 
  1003.          inputs.  A few say it means both.
  1004.          
  1005.          In any case, I believe DOCTOR is both.  I know it is the 
  1006.          former.  I gained the information in DOCTOR from a single 
  1007.          book that has a few chapters on childhood diseases.  As in 
  1008.          building ANY knowledge base the first thing to do is obtain 
  1009.          the knowledge. 
  1010.          
  1011.          I began DOCTOR as I began ANIMAL: listing all the possible 
  1012.          diseases that a child could have (finding all the terminators 
  1013.          in the tree), and I gathered information about each one that 
  1014.          would make it unique from the others.
  1015.          
  1016.          However, here is were the similarity ceases.  I realized that 
  1017.          my knowledge would be far from complete.  That is, it would 
  1018.          be nearly impossible for me to group the different diseases 
  1019.          into categories based on the knowledge source I had.  So, I 
  1020.          simply started entering diseases into the KB, MAKING SURE 
  1021.          THAT EVERY DISEASE ENTERED WAS UNIQUE FROM THE DISEASES 
  1022.          ENTERED PREVIOUSLY. 
  1023.          
  1024.          That is the key to making a non fully structured KB work.  
  1025.          Although, with the KB given it, ESIE may ask some questions 
  1026.          that have absolutely no pertinence as to the child's disease 
  1027.          (i.e. he may or may not have the symptom and answering it 
  1028.          will not help the determination), and the user may be asked 
  1029.          to answer more questions than with a fully structured KB, but 
  1030.          the KB will still be GREAT. 
  1031.          
  1032.          When building a non fully structured KB you must look out for 
  1033.          positioning in the rule base.  It is the only time you must 
  1034.          do so.  Let me explain.  When you have a KB that is not fully 
  1035.          structured, rule positioning can be important.  You need only 
  1036.          worry about rule positioning if the <variables> in the 
  1037.          conclusions are identical, and the comparators are similar.  
  1038.          This becomes obvious in the following two rule example: 
  1039.          
  1040.                if has.fever is yes
  1041.                then type.disease is roseola
  1042.          
  1043.                if has.fever is yes
  1044.                and has.inflammed.ears is yes
  1045.                then type.disease is serious.ear.infection
  1046.                                                                Page 20
  1047.          
  1048.          As ESIE is searching for 'type.disease' he comes across the 
  1049.          first rule and invokes a QUESTION for has.fever.  The end 
  1050.          user specifies yes so ESIE concludes that type.disease is 
  1051.          roseola and terminates this consultation.  However, the child 
  1052.          really had a serious ear infection, but ESIE never got that 
  1053.          far.  A better way to arange the rules would be: 
  1054.          
  1055.                if has.fever is yes
  1056.                and has.inflammed.ears is yes
  1057.                then type.disease is serious.ear.infection
  1058.          
  1059.                if has.fever is yes
  1060.                then type.disease is roseola
  1061.          
  1062.          Now, when ESIE encounters the first rule he invokes a 
  1063.          question to find has.fever.  Since the answer is yes he 
  1064.          invokes the QUESTION to determine if the child has inflammed 
  1065.          ears.  Since the answer is yes, ESIE reaches the correct 
  1066.          conclusion that the type.disease is a serious ear infection. 
  1067.          
  1068.          In general, you only need to worry about rule placement in 
  1069.          the IF catagory, when the <variables> in the conclusion are 
  1070.          identical, and the comparators are similar.  Of course, if 
  1071.          your information about 'roseola' was more complete you could 
  1072.          simply add another rule to make it unique from serious ear 
  1073.          infection.  If your information is not complete, then you can 
  1074.          add a rule like the one above to be your "catch all."  If 
  1075.          none of the other has.fever rules fire, then the disease must 
  1076.          be roseola. 
  1077.          
  1078.          Take a minute to look at the DOCTOR KB and compare it to the 
  1079.          KB for ANIMAL.  Any tree you try to put together for DOCTOR 
  1080.          will look much different than the fully structured one for 
  1081.          ANIMAL.  Do not be fooled into thinking that the only type of 
  1082.          KB you plan on doing is the fully structured kind.  Nearly 
  1083.          every usable KB is of the non fully structured variety, and, 
  1084.          believe me, they are more than successful.  Building 
  1085.          structured KBs can often be nearly impossible. 
  1086.          
  1087.          A system such as ANIMAL is often used as a learning tool in 
  1088.          expert system education because biologists have spent 
  1089.          lifetimes building schema to classify the animals, and it is 
  1090.          possible to build fully structured knowledge bases with this 
  1091.          very scientific, well documented, information.
  1092.          
  1093.  
  1094.  
  1095.  
  1096.  
  1097.  
  1098.  
  1099.  
  1100.  
  1101.                                                                Page 21
  1102.  
  1103.          
  1104.          Some Example Knowledge Bases                         Glass
  1105.          
  1106.          
  1107.          The GLASS KB is included simply for your edification and my 
  1108.          delight.  I did not build it.  It is included to show another 
  1109.          style of writing a KB.  If you are new to ESs, then your 
  1110.          style might be quite similar to the one in GLASS.  I include 
  1111.          it for my delight because it was built by a person with no AI 
  1112.          experience or AI education at all.  It shows how easy ESIE is 
  1113.          to use.  Software like ESIE may well help the spread of AI. 
  1114.          
  1115.  
  1116.  
  1117.  
  1118.  
  1119.  
  1120.  
  1121.  
  1122.  
  1123.  
  1124.  
  1125.  
  1126.  
  1127.  
  1128.  
  1129.  
  1130.  
  1131.  
  1132.  
  1133.  
  1134.  
  1135.  
  1136.  
  1137.  
  1138.  
  1139.  
  1140.  
  1141.  
  1142.  
  1143.  
  1144.  
  1145.  
  1146.  
  1147.  
  1148.  
  1149.  
  1150.  
  1151.  
  1152.  
  1153.  
  1154.  
  1155.  
  1156.                                                                Page 22
  1157.  
  1158.          
  1159.                         Building Your Own Knowledge Base
  1160.  
  1161.                    
  1162.          The first thing you must do when you decide to build an AI 
  1163.          tool is to decide what your area is.  This may be a tough 
  1164.          decision.  It should be something were there is an abundance 
  1165.          of information, and where that information can be translated 
  1166.          into production rules.  The area you are thinking about 
  1167.          building an ES for is often called the "target" in AI 
  1168.          parlance. 
  1169.          
  1170.          In general, a KB is a set of problem and solution entities 
  1171.          applied to the problem set.  Since it may be difficult, or 
  1172.          impossible, to code the decision-making process from the 
  1173.          expert's frame of reference to the machine's, it is a good 
  1174.          idea to spend a fair amount of time researching where you 
  1175.          want to apply AI.  
  1176.          
  1177.          ESs are generally required where human action or knowledge is 
  1178.          not easily available to solve the problem or to make a 
  1179.          decision.  This may be occurring due to a shortage of 
  1180.          qualified personel or due to the cost of hiring and training 
  1181.          such personel.  Another important criterion is that the 
  1182.          "rules" the experts use to make a decision can easily be 
  1183.          recalled by them. 
  1184.          
  1185.          For example, you may be able to code the "rules" that go into 
  1186.          the maintenance of a '57 Chevy, as they would obvious and 
  1187.          explainable by a mechanic.  However, the decisions a finance 
  1188.          officer of a large corporation makes when investing in stock 
  1189.          may be impossible to code into rules because he uses 
  1190.          intuition to guide his decisions.
  1191.          
  1192.          Once the application has been decided on, then you must begin 
  1193.          gathering knowledge in the form of production rules.  These 
  1194.          rules resemble an "IF-THEN" relationship.  IF one thing is 
  1195.          true THEN do another.  For example, IF the car won't start 
  1196.          THEN check the battery.  Defining these IF-THEN rules, by 
  1197.          interviewing and consulting experts in the target field, is 
  1198.          how you build a KB. 
  1199.          
  1200.          It is important to check the qualifications of the expert as 
  1201.          well as the dedication of the expert to develop the system.  
  1202.          A common language to be used between you and the expert(s) 
  1203.          should be developed right away.  Communication is essential!  
  1204.          This common speaking ground should be mnemonic and very easy 
  1205.          to use.  A review of the KB and KB structure with as many of 
  1206.          the experts who helped you develop the knowledge base is 
  1207.          almost always a good idea.  They will tell you where they 
  1208.          said one thing yet meant another, or possibly were you made a 
  1209.          mistake in creating a production rule. 
  1210.  
  1211.                                                                Page 23
  1212.          However, you may find it worthwhile to train the experts in 
  1213.          the building of the knowledge base themselves.  An even 
  1214.          greater possibility for success comes if you are an expert in 
  1215.          a field and choose that field to be built into a KB.  Often, 
  1216.          experts prefer developing systems in this manner instead of 
  1217.          being interviewed by a programmer who might not have 
  1218.          excellent communications skills.  Some might even get carried 
  1219.          away and develop a system par none.  ESIE is very easy to 
  1220.          use, and the expert might even have some fun coding his 
  1221.          knowledge into a KB.  Most people like to show off their 
  1222.          expertise when given a chance! 
  1223.          
  1224.          The gathering of information is often the toughest and the 
  1225.          most discouraging step in building a KB.  I urge you not to 
  1226.          give up if it seems impossible or is very frustrating.  It 
  1227.          will probably fall very easily into place when you start 
  1228.          building the KB.  
  1229.  
  1230.          Do not worry if you do not have complete knowledge, or that 
  1231.          your knowledge is only rudimentary when you start building 
  1232.          the ES:  you can, and should, go back to the expert to ask 
  1233.          new questions as the KB takes form.  One of the best possible 
  1234.          situations is when you are also the expert that is building 
  1235.          the KB.  It is usually pretty easy to ask yourself questions.
  1236.          
  1237.          Most people have many things that they are very good at.  
  1238.          Several of these might be built into KBs.  I assume there is 
  1239.          something you are an expert in and can put your information 
  1240.          into some production rules.  This is often one of the most 
  1241.          productive environments for building KBs.  Try it: you may 
  1242.          even find that someone wants to buy it from you. 
  1243.          
  1244.          If you are your own expert in building a KB, try to do two 
  1245.          things:  1) be objective.  If you have an area that you are a 
  1246.          little fuzzy about, or where there is significant difference 
  1247.          of opinion among your technical peers, then get a second or 
  1248.          third opinion.  2)  be understanding.  Allow a person not 
  1249.          versed in your field to use the system as it begins taking 
  1250.          shape.  He/she will often tell you where something doesn't 
  1251.          make sense.  While it makes sense to you and is perfectly 
  1252.          obvious, remember that you are building this system to help 
  1253.          the kind of person sitting in that chair. 
  1254.          
  1255.          After you have gathered a good chunk of information, or at 
  1256.          least enough to get started, you should start entering the 
  1257.          knowledge as rules in the KB.  In ESIE there are five kinds 
  1258.          of rules.  Now would be a good time to read The ESIE Rule 
  1259.          Structure in the manual.  What you read in that section will 
  1260.          be the types of rules entered into the KB.  When you get 
  1261.          started with building your KB you will find that building 
  1262.          these types of rules often comes naturally and intuitively.  
  1263.  
  1264.          No real work should be expended in translating knowledge into 
  1265.          rules.  If it is a chore for you, then relax: you are trying 
  1266.                                                                Page 24
  1267.          too hard, probably to keep the KB structured and coherent.  
  1268.          Do not attempt this at first.  You can always go back and 
  1269.          make the KB "pretty" after the knowledge is in there.  Simply 
  1270.          think about the information you have and how that would look 
  1271.          translated LITERALLY into an IF-THEN construct.  Then type 
  1272.          that in. 
  1273.          
  1274.          Entering rules in the KB is easy.  You use your own word 
  1275.          processor (see the section on ESIE Requirements in the manual 
  1276.          to make sure your editor is compatible) and type in the rules 
  1277.          as you would type in a letter to an old friend.  The rules in 
  1278.          ESIE can be entered into the KB in free format.  That is, the 
  1279.          KB can look pretty strange when you are through with it.  For 
  1280.          example, the following two KBs are identical: 
  1281.          
  1282.               goal is type.animal
  1283.          
  1284.               if has.backbone is yes
  1285.               and has.finger.wings is yes
  1286.               then type.animal is bat
  1287.          
  1288.               question has.backbone is "Does it have a backbone?"
  1289.          
  1290.               question has.finger.wings 
  1291.               is "Does it have finger wings?"
  1292.          
  1293.               answer is "Your animal is a " animal.type
  1294.          
  1295.          and this one:
  1296.                   
  1297.               goal is type.animal if has.backbone is yes and 
  1298.               has.finger.wings is yes then type.animal is bat question 
  1299.               has.backbone is "Does it have a backbone?" question 
  1300.               has.finger.wings is "Does it have finger wings?" answer 
  1301.               is "Your animal is a " animal.type 
  1302.          
  1303.          I recommend something like the former structure.
  1304.          
  1305.          I might suggest, dear reader, that you make a couple of 
  1306.          "play" KBs just to get used to ESIE, before you really dig in 
  1307.          with the real world ones.  Follow the guidelines for ESIE 
  1308.          outlined in The ESIE Rule Structure, and I'm sure you will 
  1309.          have no problem.  Although I would love to help everyone out 
  1310.          there who is trying to debug a KB, I will offer telephone 
  1311.          support only to the individuals who have paid the $145 price 
  1312.          for ESIE. 
  1313.  
  1314.          When you have enough rules in a KB to make a simple run, I 
  1315.          recommend that you test what you have.  To do this, simply 
  1316.          start ESIE and enter your KB filename in place of ANIMAL.  
  1317.          When you get to the top level I suggest you turn trace on 
  1318.          until you have the KB fully debugged.  When trace is on ESIE 
  1319.          will keep you informed of what it is doing.  It will tell you 
  1320.          what it is currently looking for and what it has learned.  
  1321.                                                                Page 25
  1322.          ESIE learns things when a QUESTION is answered and when a 
  1323.          rule is "satisfied."  Run through your KB, testing every path 
  1324.          to your terminators using the GO command.  Good luck!  (I 
  1325.          know, you are not superstitious, but it can't hurt, can it?) 
  1326.          
  1327.          One of the best hints I can give you is to use mnemonic names 
  1328.          for your <variables> and <values>.  I can remember cringing 
  1329.          when I was asked to help debug a KB with all the <variables> 
  1330.          assigned a letter designator: A1 to A287. 
  1331.          
  1332.          For the LEGALANSWERS type rule I suggest you try to restrict 
  1333.          the end user responses to as few responses as possible.  And, 
  1334.          if you want to offer multiple responses, make a valid 
  1335.          response for one question be an impossible answer for 
  1336.          another, unrelated question.  For example, if the question is 
  1337.          about what time of day it is, and you want him to answer 
  1338.          morning or afternoon, do not have numbers as legal reponses 
  1339.          or specifically ask him if it is morning or afternoon.  An 
  1340.          unexpected response may make the consultation useless. 
  1341.          
  1342.          The GOAL type rule is fairly self explanatory.
  1343.          
  1344.          I think we've talked enough about the IF-THEN rule type.
  1345.          
  1346.          On the QUESTION rule type try always to "beg the question" or 
  1347.          "bait the response" as it is sometimes called.  Remember what 
  1348.          you will accept as valid answers and try to get the user to 
  1349.          give you one of those answers through the question you are 
  1350.          asking.  Always try to be friendly, or at least not hostile, 
  1351.          in your questioning.  A good trick is to shorten the length 
  1352.          of your questioning as you get deeper into the KB.  As this 
  1353.          happens, the user will already have answered several 
  1354.          questions and may not care to continue with all the verbage.  
  1355.          You might substitute: "Does it have wings?" for "Does the 
  1356.          animal you are thinking about have wings?" if you have 
  1357.          already asked several questions.
  1358.          
  1359.          In the ANSWER type rule remember to leave a space at the end 
  1360.          of your <text> if you want one.  Try to phrase the <text> so 
  1361.          that it accounts for every possible <value> of the 
  1362.          <variable>.  Be descriptive and friendly, but remember that 
  1363.          the user has just been through a consultation, so superfluous 
  1364.          verbage is not needed. 
  1365.          
  1366.          Most of all, have fun with what you are doing!
  1367.          
  1368.  
  1369.  
  1370.  
  1371.  
  1372.  
  1373.  
  1374.  
  1375.  
  1376.                                                                Page 26
  1377.  
  1378.  
  1379.                Paying For and Obtaining the Next Version of ESIE
  1380.                                                           
  1381.          
  1382.          Now comes the part we all hate to discuss.  What is ESIE 
  1383.          going to cost?  Well, that is totally up to you.  I happen to 
  1384.          be one of those people that believe that most people are 
  1385.          honest and will pay for something they find useful.  I also 
  1386.          believe that most software costs too much, and that all AI 
  1387.          software costs way too much.  I dislike copy protection 
  1388.          schemes and there are none in ESIE. And I believe that you 
  1389.          will want to see ESIE grow and be supported. 
  1390.          
  1391.          If you feel that ESIE is useful to you, send what your 
  1392.          conscience dictates.  However, if you send at least $75 you 
  1393.          will receive the most recent version of ESIE, free.  If you 
  1394.          send at least $145 you will receive: the most recent version 
  1395.          of ESIE, fully  commented source code for ESIE (ESIE was 
  1396.          written in Pascal), my sincere thanks for your support, a 
  1397.          copy of PC-Write (c) - a shareware full-feature text editor 
  1398.          fully compatible with ESIE, and access to a help line, all 
  1399.          free. 
  1400.          
  1401.          Regardless of how you feel towards ESIE, I ask that you do 
  1402.          two things: 1)  Print and fill out the file FORM so that I 
  1403.          may keep improving ESIE, and 2) share copies of the 
  1404.          distribution diskette with at least two people, preferably 
  1405.          one of them outside your organization.  
  1406.          
  1407.          I think of ESIE as living software: software that continues 
  1408.          to develop and get better, more powerful.  I believe ESIE is 
  1409.          a useful tool as it is, but can be improved.  However, 
  1410.          support for living software must come from somebody.  Even we 
  1411.          software authors and AI researchers can't live on discovery 
  1412.          and love alone.  In shareware this support comes from you - 
  1413.          the user. 
  1414.  
  1415.          Mail and money for ESIE can be sent to: Lightwave Consultants; 
  1416.          P.O. Box 290539; Tampa, FL 33617. 
  1417.  
  1418.  
  1419.  
  1420.  
  1421.  
  1422.  
  1423.  
  1424.  
  1425.  
  1426.  
  1427.  
  1428.  
  1429.  
  1430.  
  1431.                                                                Page 27
  1432.  
  1433.          
  1434.                                   Bibliography
  1435.                      
  1436.          
  1437.          1.  Dr. Herbert Simon, "AI - The Realty and the Promise"; in 
  1438.          his lecture at "Artificial Intelligence -- Opportunities and 
  1439.          Limitations in the 80's", Miami, Florida; November 7, 1984. 
  1440.          
  1441.          AI Intelligence Report; Sendero; Phoenix, Arizona; April, 
  1442.          1985. 
  1443.  
  1444.          AI Magazine; American Association for Artificial 
  1445.          Intelligence; Menlo Park, CA; Fall 1985.
  1446.          
  1447.          AI Magazine; American Association for Artificial 
  1448.          Intelligence; Menlo Park, CA; Winter 1985.
  1449.          
  1450.          Applied Artificial Intelligence Reporter; University of 
  1451.          Miami; Miami, Florida; October 1984. 
  1452.          
  1453.          Executive Briefing Artificial Intelligence; Longman Crown; 
  1454.          Reston, Virginia; 1984. 
  1455.          
  1456.          The First Conference on Artificial Intelligence Applications; 
  1457.          Sponsered by the IEEE Computer Society; Denver; Decemeber 
  1458.          5-7, 1984. 
  1459.          
  1460.          Proceedings:  AI - Opportunities and Limitations in the 80's; 
  1461.          ICS Research Institute, University of Miami; Miami, Florida, 
  1462.          November 7, 1984. 
  1463.          
  1464.          Proceedings:  IEEE Workshop on Principles of Knowledge-based 
  1465.          Systems; Sponsored by the IEEE Computer Society; Denver; 
  1466.          December 3-4, 1984.
  1467.  
  1468.  
  1469.  
  1470.  
  1471.  
  1472.  
  1473.  
  1474.  
  1475.  
  1476.  
  1477.  
  1478.  
  1479.  
  1480.  
  1481.  
  1482.  
  1483.  
  1484.  
  1485.  
  1486.                                                                Page 28
  1487.  
  1488.          
  1489.                                    Biography
  1490.                   
  1491.          
  1492.          I think it important that I tell you a little about who I am.  
  1493.          My name is Edward Reasor, and I own and operate Lightwave 
  1494.          Consultants.
  1495.          
  1496.          My Artificial Intelligence training began in college, but was 
  1497.          not used for some time afterward, as I was employed in a 
  1498.          rather traditional DP environment.  After having worked for 
  1499.          this Fortune 500 company for a few years, a co-worker and I 
  1500.          convinced management that the time was right to use AI.  
  1501.          After building the AI research department, and working in 
  1502.          that department for a few years, I struck out on my own. 
  1503.          
  1504.          I have several expert systems to my credit, the names of 
  1505.          which can not be disclosed here. 
  1506.  
  1507.          I am a member of the American Association for Artificial 
  1508.          Intelligence and the Institute of Electrical and Electronics
  1509.          Engineers.
  1510.  
  1511.  
  1512.  
  1513.  
  1514.  
  1515.  
  1516.  
  1517.  
  1518.  
  1519.  
  1520.  
  1521.  
  1522.  
  1523.  
  1524.  
  1525.  
  1526.  
  1527.  
  1528.  
  1529.  
  1530.  
  1531.  
  1532.  
  1533.  
  1534.  
  1535.  
  1536.  
  1537.  
  1538.  
  1539.  
  1540.  
  1541.